Accurately separating a foreground image from background image requires estimating full and partial pixel coverage, a process referred to as matting. Matting is often used to separate a foreground image (such as a person) from a background image (such as a particular setting). This process can be difficult because pixels in an unknown region (the area around the boundary of a foreground object and the background in an image) are a blend of foreground and background colors. Estimating the opacity and true background and foreground colors in the unknown region to give the combined image a smooth and blended appearance is the goal of matting.
Studio quality matting can be achieved in a professional studio (e.g., a Hollywood movie set) utilizing a very large, single-colored background screen. The background can be any color that is uniform and distinct, but green and blue backgrounds are most commonly used. The actor or person being filmed in front of the screen cannot wear clothing that is similar in color to the screen or the matting process may not work properly. Unfortunately, such a large, single-colored background screen is impractical for a home studio (or any user that lacks the professional skills and resources typical in a professional studio). Further, when a foreground is against a solid colored background (e.g., a green screen), the light being reflected from the background can contaminate the foreground, creating a “halo” of the background colors along the edges of the foreground. The process of despillling refers to removing the artifacts from the foreground by estimating the true foreground color for the pixels.